package main

import "github.com/gin-gonic/gin"

func main() {
	g := gin.Default()
	g.POST("/", upload)
	g.Run()
}
func upload(ctx *gin.Context) {
	file, err := ctx.FormFile("file")
	if err != nil {
		return
	} else {
		ctx.SaveUploadedFile(file, "D:\\godev\\imag\\"+file.Filename)
	}
}
